package cn.zhfeat.hatch.web.utils;


/**
 * @explain
 * @author wschenyongyin
 * @date 2017年5月3日
 */
public class ConfigUtil {

	
//	public static String SCHEMA_NAME = "scrm-public"; //dev
	public static String SCHEMA_NAME = "scrm_public"; //online & test

	// 配置token有效时间
	public static int ACCESS_TOKEN_TIME = 1 * 24 * 60 * 60;// 单位秒
	// todo:pwd md5盐值
	public static String MD5_PWD_STR = "CECOOK_YZL_@)!^";
	// todo:sms验证码长度
	public static int ALIDAYU_SMS_CHECK_CODE_LENGTH = 6;

	public static String PARAMETER_ERROR_CODE = "error_code";
	public static String PARAMETER_ERROR_MSG = "error_msg";

	// 生成随机数的最大和最小值
	public static int RANDOM_MAXVALUE = 30;
	public static int RANDOM_MINVALUE = 5;

	/*
	 * ali dayu start
	 */
	public static String ALIDAYU_SMS_URL = "http://gw.api.taobao.com/router/rest";
	public static String ALIDAYU_SMS_APPKEY = "23523438";
	public static String ALIDAYU_SMS_SECRET = "221e92217b31a02c2a5620dc80f15d74";
	public static String ALIDAYU_SMS_TYPE = "normal";
	public static String ALIDAYU_SMS_EXTEND = "";
	public static String ALIDAYU_SMS_PRODUCT = "zhfeat";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_REG = "注册验证";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_LOGIN = "登录验证";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_CHANGE = "变更验证";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_IDENTITY = "身份验证";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_ACTIVITY = "活动验证";
	public static String ALIDAYU_SMS_FREE_SIGN_NAME_BIND = "绑定验证";
	public static String ALIDAYU_SMS_TEMPLATE_CODE_BIND = "SMS_41600023";// 身份验证验证码模板ID
	public static String ALIDAYU_SMS_CODE_TYPE_BIND = "bind_code";// 绑定验证

	public static String ALIDAYU_SMS_TEMPLATE_CODE_IDENTITY = "SMS_11625303";// 身份验证验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_LOGIN = "SMS_11625301";// 登录确认验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_LOGIN_REEOR = "SMS_11625300";// 登录异常验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_REG = "SMS_11625299";// 注册验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_ACTIVITY = "SMS_11625298";// 活动确认验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_CHANGE_PWD = "SMS_11625297";// 修改密码验证码模板ID
	public static String ALIDAYU_SMS_TEMPLATE_CODE_CHANGE_INFO = "SMS_11625296";// 信息变更验证码ID
	public static int ALIDAYU_SMS_SEND_INTERVAL = 60;// 发送验证码的间隔
	public static int ALIDAYU_SMS_EXPIRE_TIME = 5;// 发送的验证码有效时间，分钟

	public static String ALIDAYU_SMS_CODE_TYPE_REG = "reg_code";// 发送注册类型的验证码
	public static String ALIDAYU_SMS_CODE_TYPE_LOGIN = "login_code";// 发送登录验证码
	public static String ALIDAYU_SMS_CODE_TYPE_CHANGE = "change_code";// 发送变更身份的验证码
	public static String ALIDAYU_SMS_CODE_TYPE_IDENTITY = "identity_code";// 发送身份验证的验证码6
	public static String ALIDAYU_SMS_CODE_TYPE_ACTIVITY = "activity_code";// 发送活动验证的验证码
	/*
	 * ali dayu end
	 */

	// 默认每页数据的大小
	public static int LIMIT_SIZE = 10;
	// 二维码图片的宽
	public static int QR_WIDTH = 300;
	// 二维码图片的高
	public static int QR_HEIGHT = 300;
	// 二维码图片类型
	public static String QR_FORMAT = "jpg";
	// 标记用户token是否有效 默认无效
	public static boolean TOKEN_VALID = true;
	// 标记token是否为空
	public static String TOKEN_IS_EMPTY = "sss";

	public final static  String REDIS_KEY = "cecook";

	//本地地址
//	public static String LOCAL_PROJECT_URL="http://localhost:8080/scrm/";
	
	//测试域名
//	public final static String FILE_URL="http://scrm.cecook.net";
	//微信appid
//	public final static String WEIXIN_APPID="wx28d461aa329540cf";
//	public final static String WEIXIN_APPID="wx08e088fba3e81ec3";
		/*attribute
	 * sys
	 */
	//十天登录，token过期时间
	public static int ACCESS_TOKEN_TIME_TEN = 10 * 24 * 60 * 60;
	//十天登陆，cookie过期时间
	public static int COOKIE_TIME_TEN = 10 * 24 * 60 * 60;
	//十天登录判断
	public static String TEN_LOGIN_STR = "yes";
	//0和1
	public static final Long CODE_ZERO = 0l;
	public static final Long CODE_ONE = 1l;
	//定义公有数据库
	public final static String[] scrm_public = { 
        "bm_activity_model","bm_marketing_model","sys_authority",
        "sys_company", "sys_department", "sys_login_log",
        "sys_mail_account", "sys_role", "sys_role_authority", "sys_schema_database",
        "sys_sms_code","sys_social_account","sys_tenant_database","sms_msg_log",
        "sys_user","sys_user_role","dock_authorize_info","dock_product_service","dock_product_synch",
        "address_code","base_goods_medicine_info","sys_operator_list","sys_weixin_info","auto_market_template_public"
        ,"auto_market_point_info_public","sms_msg_log","base_coupon_code"
	};
	
	//数据管理导出失败的数据redis标识
	public static String DATA_MANAGE_LISTERRORKEY = "data_Manage_listErrorKey";
	
	//获取全部用户及其对应的状态的redis标识
	public static String ALL_USER_STATE = "all_user_state";
	
	//使用该key来当锁
	public static String UPDATE_SMS_NUM = "update_sms_num_key";
	
	//使用该key作为Session生成规则
	public static String REDIS_USER_SESSION_KEY = "redis_user_session_key_";

	//用于生成ticket的秘钥
	public static String THIRD_TOKEN_PASSWORD = "cecook_third_token";
	
	//用于保存租户数据导入状态的sessionKey
	public static String IMPORT_MEMBER_DATA_TAG = "scrm:session:member:tag:import:";
	
	//会员导入失败数据导出标识
	public static String IMPORT_MEMBER_ERROR_EXPORT = "scrm:session:member:error:exportList:";
	
	//会员导入失败数据记录标识
	public static String IMPORT_MEMBER_ERROR_EXPORT_NUM = "scrm:session:member:error:num:";
	
	//会员导入成功数据记录标识
	public static String IMPORT_MEMBER_SUCCESS_EXPORT_NUM = "scrm:session:member:success:num:";
}
